package test4;

public class Dog extends Pet {
    public String variety;//品种类

    public Dog(String name, int health, int love, String variety) {
        super(name, health, love);
        this.variety = variety;
    }

    public String getVariety() {
        return variety;
    }

    public void setVariety(String variety) {
        this.variety = variety;
    }

    public Dog() {
    }
    @Override
    void eat() {
        System.out.println("给狗吃骨头");
    }

    @Override
    void show() {
        System.out.println("宠物"+name+"的自白："+"\n我的名字叫" + name +
                ", 我的健康值为：：" + health +
                ", 我和主人的亲密度为：" + love +
                "\n我是一只" + variety);
    }

}
